package test;

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.net.Socket;

public class JohnClient {

	public static void main(String[] args) throws Exception{
		Socket sk=new Socket("127.0.0.1",4440);
		
		OutputStream out=sk.getOutputStream();
		out.write("I am Client!\n".getBytes());
		
		BufferedReader reader=new BufferedReader(new InputStreamReader(sk.getInputStream()));
		String line =reader.readLine();
		System.out.println(line);
		
		reader.close();
		out.close();
		sk.close();
		
		

	}

}
